package cn.eshore.bnet.bpm.service.action;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.jbpm.graph.def.Action;
import org.jbpm.graph.exe.ExecutionContext;
import org.jbpm.graph.exe.Token;

public class LogAction extends Action {
    static Log LOG = LogFactory.getLog(LogAction.class);

    public void execute(ExecutionContext executionContext) throws Exception {
        final Token rootToken = executionContext.getContextInstance().getProcessInstance().getRootToken();
  //      rootToken.getProcessInstance().getContextInstance().setVariable("PRE_NODE_ID", rootToken.getNode().getId(), rootToken);
        LOG.info("enter node:"
                + rootToken.getNode().getName());
    }
}
